package com.imyours.net.messagedisposer;

import net.sf.json.JSONObject;

import com.imyours.net.result.ExecuteResult;
import com.imyours.net.result.LoginResult;

/**
 * 处理
 * 
 * @author SLevenc
 * 
 */
public class LoginMessageDisposer extends MessageDisposer {

	public LoginMessageDisposer(ExecuteResult result, String text) {
		super(result, text);
	}

	@Override
	protected void execute(JSONObject jo) throws Throwable {
		String sessionId = jo.getString("sessionId");
		((LoginResult) result).setSessionId(sessionId);
		result.setSuccessed(true);

	}

}
